import os
import json

DEFAULT_CONF = os.path.dirname(os.path.abspath(__file__)) + os.path.sep + 'center_default_config'

def load_config(config_file):
    try:
        fp = open(config_file)
    except IOError, e:
        print e
        return None
    else:
        config = json.load(fp)
        fp.close()
        return config

global_config = load_config(DEFAULT_CONF)
